﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class MasterPage1 : System.Web.UI.MasterPage
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!Page.IsPostBack)
        {
            bindData();
        }
        Response.Cache.SetNoStore();
        Response.Cache.SetCacheability(HttpCacheability.NoCache);
    }

    public void bindData()
    {
        StaticData data = new StaticData();
        OboutDropDownList1.DataSource = data.listLinhVuc;
        OboutDropDownList1.DataBind();
        OboutDropDownList2.DataSource = data.listQuan;
        OboutDropDownList2.DataBind();
    }
    protected void OboutButton1_Click(object sender, EventArgs e)
    {
        string Key = OboutTextBox1.Text;
        string LinhVuc = OboutDropDownList1.SelectedValue;
        string Quan = OboutDropDownList2.SelectedValue;
        Server.Transfer("Search.aspx?Key=" + Key + "&LinhVuc=" + LinhVuc + "&Quan=" + Quan);
    }
}
